﻿using Orchard.ContentManagement.MetaData;
using Orchard.Data.Migration;

namespace Wolf.LoggedInUsers
{
    public class Migrations : DataMigrationImpl
    {
        public int Create()
        {
            ContentDefinitionManager.AlterTypeDefinition("LoggedInUsersWidget",
                cfg => cfg
                    .DisplayedAs("Logged In Users")
                    .WithPart("LoggedInUsersPart")
                    .WithPart("CommonPart")
                    .WithPart("WidgetPart")
                    .WithSetting("Stereotype", "Widget")
                );

            return 1;
        }
    }
}